﻿#light

open FsStoryRunner
open Xunit
open MutatedTurtleMovesImpl

(*
In order to have fun
 As a consumer of the turtle API
 I want to be able to move the turtle
*)

[<Fact>]
let MoveTurtle() = 
       given ATurtle
    |> whens MovesOneStepForward
    |> thens IsMovedOneStepForward
    |> andThens (RotationIs 0)
    |> endStory
    
[<Fact>]
let MoveTurtleToPosition() = 
       given ATurtle
    |> andGiven IsRotated90DegreesToTheRight
    |> whens (TurtleWalksSteps 9)
    |> thens (TurtleIsLocatedAt (0,9))   
    |> endStory

[<Fact>]
let NotFullyImplementedStory() = 
       given ATurtle
    |> andGiven SomethingElse
    |> whens SomethingHappens
    |> thens SomethingHappens
    |> andThens (WeCanSupplyArgumentsAsWell 0)
    |> endStory

//test
[<Fact>]
let MoveTurtleToPositionParameterInNameHack() = 
       given ATurtle
    |> andGiven IsRotated90DegreesToTheRight
    |> whens (TurtleWalks 9 Steps)
    |> thens (TurtleIsLocatedAt (0,9))   
    |> endStory